home *** CD-ROM | disk | FTP | other *** search
/ MacFormat 1999 Spring / macformat-077.iso / Shareware Plus / Development / Akua Sweets 131 / Akua Sweets Examples / Imaging / Spiral Away < prev    next >
Encoding:
Text File  |  1999-03-04  |  699 b   |  38 lines  |  [TEXT/ToyS]

  1. property gasWin : 0
  2. property gasLoc : {40, 60}
  3.  
  4. global gasPic
  5.  
  6.  
  7. on run
  8.     open (choose file)
  9. end run
  10.  
  11.  
  12. on open fsObj
  13.     set gasWin to display drawing titled ¬
  14.         "Wheeee!" with dimensions {320, 320} ¬
  15.         located at gasLoc ¬
  16.         starting with (the image from fsObj)
  17.     
  18.     set gasPic to capture picture from gasWin
  19.     
  20.     draw a string into gasWin ¬
  21.         offset by {160, 160} ¬
  22.         using data "Akua Sweets!" with a clear slate
  23. end open
  24.  
  25.  
  26. on idle
  27.     set gasPic to rotate image gasPic by 50
  28.     draw a picture into gasWin using data gasPic inside of {0, 0, 320, 320} without recording
  29.     return 1
  30. end idle
  31.  
  32.  
  33. on quit
  34.     set gasPic to 0
  35.     set gasLoc to screen location of (display drawing gasWin with disposal)
  36.     continue quit
  37. end quit
  38.